import request from '@/utils/request'

// 查询人员信息列表
export function listPyr(query) {
  return request({
    url: '/system/pyr/list',
    method: 'get',
    params: query
  })
}

// 查询人员信息详细
export function getPyr(id) {
  return request({
    url: '/system/pyr/' + id,
    method: 'get'
  })
}

// 新增人员信息
export function addPyr(data) {
  return request({
    url: '/system/pyr',
    method: 'post',
    data: data
  })
}

// 修改人员信息
export function updatePyr(data) {
  return request({
    url: '/system/pyr',
    method: 'put',
    data: data
  })
}

// 删除人员信息
export function delPyr(id) {
  return request({
    url: '/system/pyr/' + id,
    method: 'delete'
  })
}

// 导出人员信息
export function exportPyr(query) {
  return request({
    url: '/system/pyr/export',
    method: 'get',
    params: query
  })
}

// 导入人员信息
export function importPyr(data) {
  return request({
    url: '/system/pyr/importData',
    method: 'post',
    data: data
  })
}

// 下载人员信息导入模板
export function importTemplate() {
  return request({
    url: '/system/pyr/download/pyrmb',
    method: 'get'
  })
}